//
//  SignTabView.swift
//  nurseApp
//
//  Created by cyptt on 2022/7/14.
//

import UIKit

import SnapKit

//完成界面几中类型
public enum SIGN_TAB_TYPE {
   case SIGN  //签署
   case SIGN_FINISH     //签署完成
   case FEIQI          //废弃
}
class SignTabView: UIView {
  
    var tabMarginBotton:Constraint?
    var viewManage:SignViewManage?

    private var signType:SIGN_TAB_TYPE?

    init(viewM:SignViewManage?,type:SIGN_TAB_TYPE?){
        super.init(frame: CGRect.zero)
        self.viewManage = viewM
        self.signType = type
        setUI()
     
   
    }
    init(){
        super.init(frame: CGRect.zero)
    }
    func setUI(){
        
   
        self.addSubview(self.tabView)

       
       self.backgroundColor = UIColor.white
        self.setPosition()
        
    }
    override func layoutSubviews() {
        super.layoutSubviews()
      
        
       
    }
    
    required init?(coder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }
    
   
    
    
    
    func setPosition(){
        self.tabView.snp.makeConstraints { make in
            make.left.equalTo(0)
            make.right.equalTo(0)
            make.top.equalTo(0)
            make.bottom.equalTo(0)
       
        }
       
    }
 

    lazy var tabView = {()->UITableView in
        let tabV = UITableView.init();
        tabV.delegate = self.viewManage;
        tabV.dataSource = self.viewManage;
        tabV.backgroundColor = UIColor.clear
        tabV.separatorColor = UIColor.clear
        let result:String =  CHUtils.getClassName(CHSelecAlltTestTabCell.self)
//
        tabV.register(UINib.init(nibName: result, bundle: nil), forCellReuseIdentifier: result + "ID")
//        tabV.register(CHSelecAlltTestTabCell.self, forCellReuseIdentifier: result + "ID")
        return tabV;
    }()
}
